#ifndef _GLOBAL_CONFIG_H
#define _GLOBAL_CONFIG_H


#include <WString.h>

/*----------------INMP441 配置部分---------------*/
/* INMP 引脚设置*/
//#define I2S_WS 17
//#define I2S_SD 3
//#define I2S_SCK 18
#define I2S_WS      (4)
#define I2S_SD      (6)
#define I2S_SCK     (5)

#define I2S_PORT_0              (I2S_NUM_0)
#define SAMPLE_RATE             (16000)
#define RECORD_TIME_SECONDS     (10)
#define BUFFER_SIZE             (SAMPLE_RATE * RECORD_TIME_SECONDS)

/*----------------MAX98357 配置部分---------------*/
// 1、修改 MAX98357 喇叭接口
#define I2S_DOUT (7)
#define I2S_BCLK (15)
#define I2S_LRC (16)


/*-----------------------公共部分--------------------------*/
//关于WS2812B
#define PIN_PIXS        (48)
#define PIX_NUM         (1)
#define CHUNK_SIZE      (2048)


static const char* ssid = "H3C_201";
static const char* password = "cy0515cy0515";

#if 1 /*-------------Xinghuo ASR 配置部分--------------*/
// 使用 static const
static const int recordTimeSeconds = 3;



// 讯飞STT 的key
static const String STTAPPID = "5d9dd4e5";
static const char* STTAPISecret = "YjQyZDJiMjY3ZWFmNGUxZGNlODk1OTIz";
static const char* STTAPIKey = "caac28fe0d2d2ea47f1cdb7930951ee7";

//NTP 授时
static const char* ntpServer1 = "ntp.org";
static const char* ntpServer2 = "ntp.ntsc.ac.cn";
static const long gmtOffset_sec = 3600;
static const int daylightOffset_sec = 3600;
#endif 



/*-------------Baidu TTS 配置部分--------------*/
// 3、修改百度语音助手的用户信息 （tok:用户的识别）
static const char *API_KEY = "ji3O9hBBA6oX5JzWfwxzctqT";
static const char *SECRET_KEY = "SedCEs8yfNIBlmLOwt1Dyuo3n2uBUyXi";
#define CLIENT_ID API_KEY  //两者是一回事
#define CLIENT_SECRET SECRET_KEY
static const char* GRANT_TYPE = "client_credentials";
//以下为选填选项
static const int PER = 103;//音色（度米朵）
static const int SPD = 5;//语速
static const int PIT = 5;//音调
static const int VOL = 5;//音量
static const int AUE = 6;//3为mp3格式(默认)； 4为pcm-16k；5为pcm-8k；6为wav（内容同pcm-16k）; 


//可用的地址：
//http://tsn.baidu.com/text2audio 或 https://tsn.baidu.com/text2audio
static const char *TTS_URL = "https://tsn.baidu.com/text2audio";


#endif /*_GLOBAL_CONFIG_H*/


